- /* sdfcnbyf.cpp by K.Tsuru */
- // function ID 3700 DRADIX
- /*******************************
- SDouble class
- read constant number from a file
- ********************************/
- #ifndef SN_H
- #include "sn.h"
- #endif
- bool SetConstByFile(const char* fname,
- SDouble (*pfunc)(const SDouble* c, SDouble (*pf)()),
- SDouble (*pfCalcFunc)(), uint ef){
- RealSize C;
- SDouble q;
- bool enough = true;
- if(ef == 0) ef = q.EffFig();
- C.SetEffFig(ef, C.TEMP_EXTEND);
- q = q.ReadNumber(fname, q.MaxSize() + 1u);
- q.CloseReadNumber();
- //cout << "SetConstByFile() is called by " << fname <<endl;
- //Do not check the consistency with pfunc = Pi, E or Log10 to avoid the link
- //with three functions.
- //If pfCalcFunc == NULL and the figures of q is too small,a syntax error
- //will occure in the EntryConst().
- C.SetEffFig(0);
- if(q.Last() < q.EffFig()+q.Hidden()) enough = false;
- else (*pfunc)(&q, pfCalcFunc);
- return enough;
- }
sdfcnbyf.cpp : last modifiled at 2016/09/05 10:55:36(932 bytes)
created at 2017/10/07 10:22:50
The creation time of this html file is 2017/10/07 11:29:39 (Sat Oct 07 11:29:39 2017).